﻿<%@ Page Title="Home Page" Language="C#" MasterPageFile="~/Site.master" AutoEventWireup="true"
    CodeBehind="Default.aspx.cs" Inherits="CityNavigation._Default" %>

<asp:Content ID="HeaderContent" runat="server" ContentPlaceHolderID="HeadContent">
    <script src="Scripts/AutoComplete.js" type="text/javascript"></script>
    <script src="Scripts/jquery-1.4.1.min.js" type="text/javascript"></script>
</asp:Content>
<asp:Content ID="BodyContent" runat="server" ContentPlaceHolderID="MainContent">
    <script type="text/javascript">
        function showStation(id) {
            window.location.href = "LineView.aspx?id=" + escape(id);
            //sdfdsfdsfdsfdf
            //啊
        }
        function showLineIndex() {
            window.location.hash = "BusLineNav.aspx?#" + escape(id);
        }
        
    </script>
    <div align="center">
        <br />
        <br />
        <br />
        <table>
            <tr>
                <td>
                    <div style="font-size:20px;font-weight:bolder;">郑州公交查询</div>
                </td>
            </tr>
        </table>
        <br />
        <asp:MultiView ID="MultiView1" runat="server">
            <asp:View ID="View1" runat="server">
                <table style="width: 450px">
                    <tr style="width: 450px">
                        <td style="width: 190px">
                            <asp:TextBox ID="tbxStart" runat="server" Width="170px"></asp:TextBox>
                        </td>
                        <td style="width: 20px">
                            <asp:Image ID="ImgTrans" runat="server" ImageUrl="~/Img/transImg.jpg" />
                        </td>
                        <td style="width: 190px">
                            <asp:TextBox ID="tbxEnd" runat="server" Width="170px"></asp:TextBox>
                        </td>
                        <td>
                            <asp:Button ID="btnGo" runat="server" Text="怎么去" Width="90px" BackColor="#333399"
                                BorderStyle="None" Font-Bold="True" ForeColor="White" 
                                onclick="btnGo_Click1" />
                        </td>
                    </tr>
                </table>
            </asp:View>
            <asp:View ID="View2" runat="server">
                <table style="width: 450px">
                    <tr id="tr5">
                        <td colspan="3">
                            <asp:TextBox ID="tbxLine" runat="server" Width="360px"></asp:TextBox>
                        </td>
                        <td>
                            <asp:Button ID="Button3" runat="server" Text="搜索" Width="90px" BackColor="#333399"
                                BorderStyle="None" Font-Bold="True" ForeColor="White" 
                                onclick="Button3_Click" />
                        </td>
                    </tr>
                </table>
            </asp:View>
            <asp:View ID="View3" runat="server">
                <table style="width: 450px">
                    <tr>
                        <td colspan="3">
                            <asp:TextBox ID="tbxStation" runat="server" Width="360px"></asp:TextBox>
                        </td>
                        <td>
                            <asp:Button ID="Button7" runat="server" Text="搜索" Width="90px" BackColor="#333399"
                                BorderStyle="None" Font-Bold="True" ForeColor="White" 
                                onclick="Button7_Click" />
                        </td>
                    </tr>
                </table>
            </asp:View>
        </asp:MultiView>
        <table style="width: 300px">
            <tr>
                <asp:RadioButtonList ID="RadioButtonList1" runat="server" RepeatDirection="Horizontal"
                    AutoPostBack="True" OnSelectedIndexChanged="RadioButtonList1_SelectedIndexChanged">
                    <asp:ListItem>公交换乘</asp:ListItem>
                    <asp:ListItem>线路查询</asp:ListItem>
                    <asp:ListItem>站点查询</asp:ListItem>
                </asp:RadioButtonList>
            </tr>
        </table>
        <div style="position: absolute; cursor: pointer" id="popup">
            <table id="complete_table" border="0" cellspacing="0" cellpadding="0" style="background-color: White;">
                <tbody id="complete_body">
                </tbody>
            </table>
        </div>
        <br />
        <br />
        <br />
        <table style="width: 450px">
            <tr>
                <td style="width: 80px">
                    最近更新：
                </td>
                <asp:Repeater ID="rptNewLines" runat="server">
                    <ItemTemplate>
                        <td style="cursor: pointer;">
                            <asp:HyperLink ID="HyperLink1" runat="server" ForeColor="blue" NavigateUrl=<%#"~/LineView.aspx?id="+  Eval("LineName") %>><u><%# Eval("LineName") %></u></asp:HyperLink>
                        </td>
                    </ItemTemplate>
                </asp:Repeater>
            </tr>
        </table>
<%--        <table style="width: 450px">
            <tr>
                <td>
                    公交线路：
                </td>
                <asp:Repeater ID="rptHotLines" runat="server">
                    <ItemTemplate>
                        <td style="cursor: pointer">
                            <asp:HyperLink ID="HyperLink1" runat="server" ForeColor="blue"><u><%# Eval("LineName") %></u></asp:HyperLink>
                        </td>
                    </ItemTemplate>
                </asp:Repeater>
            </tr>
        </table>--%>
        <table style="width: 450px">
            <tr>
                <td style="width: 80px">
                    公交站点：
                </td>
                <asp:Repeater ID="rptHotStation" runat="server">
                    <ItemTemplate>
                        <td style="cursor: pointer;">
                            <asp:HyperLink ID="HyperLink1" runat="server" ForeColor="blue" NavigateUrl=<%#"~/StationView.aspx?id="+  Eval("StationName") %>><u><%# Eval("StationName")%></u></asp:HyperLink>
                        </td>
                    </ItemTemplate>
                </asp:Repeater>
            </tr>
        </table>
        <table style="width: 450px">
            <tr>
                <td style="width: 80px">
                    线路查询：
                </td>
                <asp:Repeater ID="rptLinesIndex" runat="server">
                    <ItemTemplate>
                        <td style="cursor: pointer">
                            <asp:HyperLink ID="HyperLink1" runat="server" ForeColor="blue"  NavigateUrl=<%#"~/BusLineNav.aspx?#" + Eval("linesIndex") %>><u><%# Eval("linesIndex")%></u></asp:HyperLink>
                        </td>
                    </ItemTemplate>
                </asp:Repeater>
            </tr>
        </table>
 
    <asp:GridView ID="GridView1" runat="server">
        <Columns>
            <asp:BoundField DataField="LinesStr" HeaderText="起始站" />
        </Columns>

    </asp:GridView>
    </div>
    <br/>
    <br/>
    <br/>
    <br/>
    <br/>
    <br/>
    <br/>
    <br/>
    <br/>
    <br/>
    <br/>
    <br/>
</asp:Content>
